.modal {
  position: absolute;
  background: var(--neutral-1);
  top: 0;
  bottom: 0;
  right: 0;
  left: 0;
  opacity: 0.4;
}

.dialog {
  --error-text: var(--dialog-error-color);
  --input-color: var(--neutral-12);
  --input-bg: var(--neutral-1);
  background: var(--dialog-bg);
  position: fixed;
  transform: translate(-50%, -50%);
  color: var(--dialog-color);
  top: 50%;
  left: 50%;
  min-width: 400px;
  max-height: 100vh;
  min-height: 200px;
  overflow: auto;
  font: var(--default-font-family);
  padding: 24px 24px 32px 24px;

  header {
    font-size: 21px;
    font-weight: 100;
  }

  a {
    color: var(--dialog-link-color);

    &:focus {
      outline: 1px solid var(--dialog-link-focus-color);
    }
  }
}

.footer {
  height: 21px;
  min-width: 240px;
  float: right;
  display: flex;
  justify-content: flex-end;
  margin-top: 20px;

  button {
    height: 21px;
    flex-grow: 1;
    margin-right: 4px;

    &:only-child {
      flex-grow: 0;
    }

    &:not(first-child) {
      margin-left: 4px;
    }
  }
}

.cancel-button,
.cancel-button-outline {
  display: block;
  position: absolute;
  width: 21px;
  height: 21px;
  border: none;
  top: 12px;
  right: 12px;
  outline: none;
}

.cancel-button-outline {
  pointer-events: none;
}

.cancel-button {
  font: initial;
  -webkit-mask: url('../../media/ic_cancel.svg');
  background-color: var(--dialog-close-icon-color);
  cursor: pointer;

  &:focus + .cancel-button-outline {
    outline-width: var(--global-focus-outline-width);
    outline-style: var(--global-focus-outline-style);
    outline-color: var(--global-focus-outline-color);
  }
}

.dialog-header {
  font-family: var(--default-font-family);
  font-size: 22px;
  font-weight: 200;
  margin: 0px 4px 0px 0px;
  padding: 0;
}
